<?php

class Twitter_Bootstrap_View_Helper_FormRender extends Zend_View_Helper_FormElement
{

    public function formRender($name, $value = null, $attribs = null, $options = null)
    {
        if (isset($attribs['viewPath'])) {
            $this->view->assign('name', $name);
            $this->view->assign('value', $value);
            $this->view->assign('attribs', $attribs);
            $this->view->assign('options', $options);
            return $this->view->render($attribs['viewPath']);
        }
        else {
            return '';
        }
    }

}